import { http } from '@/utils/http'

type IJobIntention = {
  id?: number
  userId?: number
  majorId: number
  jobType?: string
  cityName?: string
  cityCode?: number
  majorName?: string
  educationalBackground?: string
}

// 获得用户求职意向
export const ApiGetJobIntention = (id: number) => {
  return http.get<IJobIntention>('/app-api/member/job-intention/get', {id})
}

// 更新用户求职意向
export const ApiUpdateJobIntention = (data: IJobIntention) => {
  return http.put<IJobIntention>('/app-api/member/job-intention/update', data)
}

//新增用户求职意向
export const ApiAddJobIntention = (data: IJobIntention) => {
  return http.post<IJobIntention>('/app-api/member/job-intention/create', data)
}
